<%@ page language="java" contentType="text/html; charset=UTF-8"
         pageEncoding="UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<script type="text/javascript" src="${pageContext.request.contextPath}/vue.js"></script>
<script type="text/javascript" src="${pageContext.request.contextPath}/vue-resource.js"></script>
<link rel="stylesheet" href="${pageContext.request.contextPath}/css/layui.css" id="layui">
<Link rel="stylesheet" href="${pageContext.request.contextPath}/front/css/main.css">
<script src="${pageContext.request.contextPath}/layui.js"></script>

<div class="header">
    <div class="header-inner">
        <a href="${pageContext.request.contextPath}/front/index.do" class="logo">电影订票系统</a>

        <div class="right" style="float:right;width: 200px;margin-top: 20px;margin-left: 100px">

            <c:choose>
                <c:when test="${sessionScope.currentUser==null}">
                    <a href="${pageContext.request.contextPath}/front/login.jsp">
                        <button class="layui-btn layui-btn-normal layui-btn-radius">用户登录</button>
                    </a>
                </c:when>
                <c:otherwise>
                    <a href="${pageContext.request.contextPath}/front/userLogout.do">
                        <button class="layui-btn layui-btn-normal layui-btn-radius">
                            欢迎您，${sessionScope.currentUser.name}</button>
                    </a>
                </c:otherwise>
            </c:choose>

        </div>
        <form action="${pageContext.request.contextPath}/front/result.do" style="float: right" target="_blank" class="search-query">
            <input name="moviename" class="search" type="search" maxlength="30" placeholder="无聊的人已经开始搜索电影了...">
            <input class="submit" type="submit" value="">
        </form>
    </div>
</div>



